package cn.gogpay.dcb.api.entity;

import cn.gogpay.dcb.h5base.entity.BaseEntity;
import com.alibaba.fastjson.JSON;
import org.springframework.data.jpa.domain.support.AuditingEntityListener;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.EntityListeners;
import javax.persistence.MappedSuperclass;

/**
 * 是否还有免费次数查询记录
 *
 * @author huangting@gogpay.cn
 * @date 2020/1/7 19:18
 */
@Entity
@EntityListeners(AuditingEntityListener.class)
public class CountRecord extends BaseEntity {
    @Column(columnDefinition = "varchar(64) comment '卡号'")
    private String cardNo;
    @Column(columnDefinition = "varchar(64) comment '电话'")
    private String phone;
    @Column(columnDefinition = "varchar(64) comment '流水号'")
    private String requestNumber;
    @Column(columnDefinition = "varchar(64) comment '验签串'")
    private String sign;
    @Column(columnDefinition = "varchar(64) comment '请求时间-几号'")
    private String countDate;
    @Column(columnDefinition = "bit(1) comment '是否还可免费'")
    private Boolean haveFreeCount;

    @Override
    public String toString() {
        return JSON.toJSONString(this);
    }

    public String getCountDate() {
        return countDate;
    }

    public void setCountDate(String countDate) {
        this.countDate = countDate;
    }

    public Boolean getHaveFreeCount() {
        return haveFreeCount;
    }

    public void setHaveFreeCount(Boolean haveFreeCount) {
        this.haveFreeCount = haveFreeCount;
    }

    public String getCardNo() {
        return cardNo;
    }

    public void setCardNo(String cardNo) {
        this.cardNo = cardNo;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getRequestNumber() {
        return requestNumber;
    }

    public void setRequestNumber(String requestNumber) {
        this.requestNumber = requestNumber;
    }

    public String getSign() {
        return sign;
    }

    public void setSign(String sign) {
        this.sign = sign;
    }
}
